<template lang="pug">
div
  FixedScroll
    div(slot="fixed")
      PageHeader(pageTitle="缺件查询")
        div(slot="right" @click="save") 保存

      ScanSearch(
          placeholder="小票单号"
          @search="search"
          @scan="scan"
          )

    StatTable.table(
        slot="scroll"
        :headList="headList"
        :body="body"
        :isLoading="isLoading"
        )

</template>

<script>
import util from "$util"

export default {
  data() {
    return {
      searchValue: "",

      isLoading: false,
      headList: [
        { field: "a", title: "实体仓库", checked: true },
        { field: "b", title: "逻辑仓库", checked: true },
        { field: "c", title: "厂家编号", checked: true },
        { field: "d", title: "厂家名称", checked: true },
        { field: "e", title: "物料号", checked: true },
        { field: "f", title: "物料名称", checked: true },
        { field: "g", title: "仓位", checked: true },
        { field: "h", title: "批次", checked: true },
        { field: "i", title: "可用数", checked: true },
        { field: "j", title: "占用数", checked: true, isInput: true },
        { field: "k", title: "捡配数", checked: true, isInput: true },
        { field: "l", title: "物料状态", checked: true },
        { field: "m", title: "物料类型", checked: true },
        { field: "n", title: "加封状态", checked: true },
      ],
      body: {
        list: [
          {
            a: "仓库一",
            b: "库房一",
            c: "123",
            d: "工厂一",
            e: "123",
            f: "原料一",
            g: "仓位一",
            h: 200,
            i: 100,
            j: 100,
            k: 100,
            l: "状态一",
            m: "类型一",
            n: "状态一",
          },
        ],
      },
    }
  },
  methods: {
    search(value) {
      util.Toast(value)
    },
    clear() {
      this.searchValue = ""
    },
    save() {
      util.Toast("已保存")
    },
    scan() {
    },
  },
}
</script>

<style lang="stylus" scoped>

.table
  scan-table()

</style>
